import java.io.IOException;
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;


public class TrainControllerPanel {

	public static String status = "Bundle:";
	public static JLabel lblBundle; 
	public static String speed = "Speed:";
	public static JLabel lblSpeed; 
	public static String power = "Power:";
	public static JLabel lblPower; 

	static JFrame frame;

	public static void main(String[] args) throws IOException, InterruptedException {
		TrainController tc = new TrainController(null);
		EventQueue.invokeLater(new Runnable() {
			public void run() {
				try {
					TrainControllerPanel window = new TrainControllerPanel();
				} catch (Exception e) {
					e.printStackTrace();
				}
			}
		});
		tc.receive(new TNBundle());
	}

	public TrainControllerPanel() {
		initialize();
	}

	private void initialize() {
		frame = new JFrame("Train Controller");
		frame.setBounds(0, 665, 1200, 150);
		frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		frame.getContentPane().setLayout(new GridLayout(3,1,0,0));
		lblBundle = new JLabel(status);
		lblSpeed = new JLabel(speed);
		lblPower = new JLabel(power);
		frame.getContentPane().add(lblBundle);
		frame.getContentPane().add(lblSpeed);
		frame.getContentPane().add(lblPower);
		frame.setVisible(true);
	}

}
